package com.chb.app.controller;

import com.chb.app.service.BannerService;
import com.hos.entity.hos.Banner;
import com.hos.vo.Result;
import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author: 陈海彬
 * @date: Created in 2023/12/19 15:49
 * @description:
 * @modified By:
 * @version:
 */
@RestController
@RequestMapping("/app/banner")
@Api("轮播图控制层")
public class BannerController {

    @Resource
    private BannerService bannerService;


    @GetMapping
    public Result<List<Banner>> getAllBanner() {
        return new Result<>(200, "获取成功", this.bannerService.getAllBanner());
    }

    }